package com.feinno.urcs.group.siptask.task;

import com.feinno.superpojo.SuperPojo;
import com.feinno.superpojo.annotation.Field;
import com.feinno.urcs.group.GroupConfiguration;
import com.feinno.urcs.group.entity.GroupInfo;
import com.feinno.urcs.sip.UrcsSipFactory;
import com.feinno.urcs.types.MobileNo;
import org.helium.framework.task.DedicatedTaskArgs;

import javax.sip.address.SipURI;
import java.text.ParseException;

/**
 * @author Li.Hongbo <lihongbo@feinno.com>
 */
public class GroupInviteArgs extends SuperPojo implements DedicatedTaskArgs {
	@Field(id = 1)
	private int groupId;
	@Field(id = 2)
	private String domain;
	@Field(id = 3)
	private String conversationId;
	@Field(id = 4)
	private String subject;
	/**
	 * 邀请者
	 */
	@Field(id = 5)
	private MobileNo referredBy;
	/**
	 * 被邀请者
	 */
	@Field(id = 6)
	private MobileNo referredTo;

	@Field(id = 7)
	private boolean offline = false;

	@Field(id = 8)
	private boolean cancel = false;

	public boolean isCancel() {
		return cancel;
	}

	public void setCancel(boolean cancel) {
		this.cancel = cancel;
	}


	public MobileNo getReferredBy() {
		return referredBy;
	}

	public void setReferredBy(MobileNo referredBy) {
		this.referredBy = referredBy;
	}

	public MobileNo getReferredTo() {
		return referredTo;
	}

	public void setReferredTo(MobileNo referredTo) {
		this.referredTo = referredTo;
	}


	@Override
	public Object getTag() {
		return TagGenerator.generateTaskTag(referredTo, getGroupId());

	}

	public int getGroupId() {
		return groupId;
	}

	public void setGroupId(int groupId) {
		this.groupId = groupId;
	}

	public String getDomain() {
		return domain;
	}

	public void setDomain(String domain) {
		this.domain = domain;
	}

	public String getConversationId() {
		return conversationId;
	}

	public void setConversationId(String conversationId) {
		this.conversationId = conversationId;
	}

	public String getSubject() {
		return subject;
	}

	public void setSubject(String subject) {
		this.subject = subject;
	}

	public boolean isOffline() {
		return offline;
	}

	public void setOffline(boolean offline) {
		this.offline = offline;
	}
}
